package cn.dlc.com.controller;

import cn.dlc.com.entity.BaseDataArea;
import cn.dlc.com.service.IBaseDataAreaService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
* @Description 区域编码表
* @author tanzy
* @since   2021-03-30
* @version V3.2
*/
@RestController
@Slf4j
@RequestMapping()
public class BaseDataAreaController {

   @Autowired
   private IBaseDataAreaService baseDataAreaService;


    @GetMapping(value = "/baseDataAreas/all")
    public List<BaseDataArea> findAll() {
        List<BaseDataArea> baseDataAreaList = baseDataAreaService.findAll();
        if (baseDataAreaList != null) {
            return baseDataAreaList;
        } else {
            return null;
        }
    }
}
